<?
define('ROOT', $_SERVER['DOCUMENT_ROOT']);
require_once(ROOT.'/public/global.php');
require_once(ROOT.'/lang/'.$LN.'.php');
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<? require_once(ROOT.'/public/ref.php'); ?>
<title>mac-flow - “account query” 示例</title>
<meta name="description" content="mac-flow 示例" />
<meta name="keywords" content="java 流程引擎 flow" />
<script type="text/javascript">
$(function(){
	function adjust(){
		var de = document.documentElement
			, ch = de.clientHeight, cw = de.clientWidth;
		$('#body').width(cw - 16);
	}
	$(window).resize(adjust);
	adjust();
});
</script>
</head>
<body>
<? require_once(ROOT.'/public/head.php'); ?>
<div id="body">
	<div class="dir">
<? require_once('../dir.php'); ?>
	</div>
	<div class="main">
		<div id="nav">
			<div id="nav_path">
				<a href="<?=$LP?>">Home</a>
				&gt;
				<a href="<?=$LP?>mac/flow">mac-flow</a>
				&gt;
				示例
			</div>
			<div id="nav_back">
				<a href="javascript:history.back()"><?=$Msg['back']?></a>
				|
				<a href="<?=$LP?>"><?=$Msg['up']?></a> &nbsp;&nbsp;
			</div>
			<div class="clear"></div>
		</div>
<h1>mac-flow - “account query” 示例</h1>
&nbsp;&nbsp;此示例演示了固定分支的fork/join的用法：<br/>
&nbsp;&nbsp;流程图如下：
<p><img alt="图片未能加载" src="/mac/flow/img/accq.png" /></p>
&nbsp;&nbsp;生成的XML如下：
<xmp>
	<bean id="accountQryService" parent="simpleFlowService">
		<property name="flowId" value="accountQry"/>
	</bean>

	<bean id="accountQry" parent="simpleFlow" >
		<property name="flowId" value="accountQry" />
		<property name="mutex" value="false" />
		<property name="entry" value="fork" />
	</bean>

	<bean id="accountQry-fork" parent="forkNode">
		<property name="join" value="join" />
		<property name="branches">
			<set>
				<value>cash</value>
				<value>stock</value>
				<value>fund</value>
			</set>
		</property>
	</bean>

	<bean id="accountQry-cash" parent="processNode">
		<property name="handler">
			<bean class="com.boarsoft.flow.demo.query.CashHandlerImpl">
			</bean>
		</property>
		<property name="next" value="join" />
	</bean>

	<bean id="accountQry-stock" parent="processNode">
		<property name="handler">
			<bean class="com.boarsoft.flow.demo.query.StockHandlerImpl">
			</bean>
		</property>
		<property name="next" value="join" />
	</bean>

	<bean id="accountQry-fund" parent="processNode">
		<property name="handler">
			<bean class="com.boarsoft.flow.demo.query.FundHandlerImpl">
			</bean>
		</property>
		<property name="next" value="join" />
	</bean>

	<bean id="accountQry-join" parent="joinNode">
		<property name="handler">
			<bean class="com.boarsoft.flow.demo.query.SumJoinHandlerImpl">
			</bean>
		</property>
		<property name="next" value="end" />
	</bean>
</xmp>
	</div>
</div>
<? require_once(ROOT.'/public/foot.html'); ?>
</body>
</html>
<?
$fp = ROOT.$LP.'/mac/flow/demo/';
output(basename(__FILE__), $fp.'accq.html');
?>